package com.example.springcloud.service;

import com.example.springcloud.client.ProductClientFeign;
import com.example.springcloud.pojo.Product;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author: trtan
 * @date: 2021-06-13 07:37
 **/
@Service
public class ProductService {

    @Autowired
    ProductClientFeign productClientFeign;
    /**
     * 查询所有产品信息
     * @param
     * @return java.util.List<com.example.one.pojo.Product>
     * @author trtan
     * @date 2021/6/13 7:39
     */
    public List<Product> getAllProducts() {
        return productClientFeign.listProducts();
    }
}
